<?php
/*
 * @Author: 李志刚
 * @CopyRight: 2020-2030 衡水山木枝技术服务有限公司
 * @Date: 2021-10-19 10:25:01
 * @Description: 订单物流信息表
 * @LastEditors: 李志刚
 * @LastEditTime: 2021-10-21 15:01:25
 * @FilePath: /team_commission/database/migrations/shop/base/2021_10_19_102501_create_order_ship.php
 */

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateOrderShip extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('order_ships', function (Blueprint $table) {
            $table->engine = 'InnoDB';
            $table->id();
            $table->foreignId('order_id')->default(0)->comment('订单ID');
            $table->string('logistics_code', 255)->comment('物流号');
            $table->string('logistics_company', 255)->comment('快递公司名称');
            $table->dateTime('reach_at')->nullable()->comment('到达时间');
            $table->string('description', 255)->nullable()->comment('详情');
            $table->tinyInteger('del_flag')->default(0)->comment('删除状态（1删除 0正常）');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('order_ships');
    }
}
